﻿using System;
using System.Collections.Generic;
using System.Text;
using System.Threading.Tasks;
using VIP.Domain.Core.DomainObject;
using VIP.Domain.DTO;
using VIP.Domain.VO;

namespace VIP.Domain.BusServices
{
    public interface IOrderService
    {
        /// <summary>
        /// 创建一个订单
        /// </summary>
        /// <param name="dto"></param>
        /// <returns></returns>
        public Task<OrderVO> Create(CreateOrderDTO dto);
        /// <summary>
        /// 更换客户姓名
        /// </summary>
        /// <param name="id"></param>
        /// <param name="name"></param>
        /// <returns></returns>
        public Task<bool> UpdateCustomName(Guid id, string name);

        /// <summary>
        /// 
        /// </summary>
        /// <param name="dto"></param>
        /// <returns></returns>
        public Task<Guid> AddItem(Guid orderId, OrderItemDTO dto);
        /// <summary>
        /// 查询订单
        /// </summary>
        /// <param name="orderCode"></param>
        /// <returns></returns>
        public Task<OrderVO> Query(string orderCode);
    }
}
